package zuoye.SubjectDao.Test;

import zuoye.SubjectDao.DBUtil.DBUtil;

import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;

public class ddlTest {
    public static void main(String[] args) {
        String sql="create table bank1( ac varchar(20) PRIMARY key,blance float(12,2) UNSIGNED comment '余额' )";
        Connection connection = DBUtil.getConnection();

        PreparedStatement ps = null;
        ResultSet rs=null;
        try {
            ps=connection.prepareStatement(sql,ResultSet.TYPE_SCROLL_SENSITIVE,ResultSet.CONCUR_READ_ONLY);
            ps.executeUpdate();
        } catch (SQLException e) {
            e.printStackTrace();
        }finally {
            DBUtil.close(rs,ps,connection);
        }
    }
}
